Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support array literal with scalar function #8884

Merged
merged 3 commits into from
Jan 18, 2024

Conversation

jayzhan211
Copy link
Contributor

@jayzhan211 jayzhan211 commented Jan 16, 2024

Which issue does this PR close?

Closes #8873
Closes #8867

Rationale for this change

What changes are included in this PR?

Are these changes tested?

Are there any user-facing changes?

Signed-off-by: jayzhan211 <[email protected]>
@github-actions github-actions bot added sql SQL Planner sqllogictest SQL Logic Tests (.slt) labels Jan 16, 2024
@@ -459,7 +459,7 @@ AS
query error
select [1, true, null]

query error DataFusion error: This feature is not implemented: ScalarFunctions without MakeArray are not supported: now()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add more to covert Struct?

Signed-off-by: jayzhan211 <[email protected]>
Copy link
Contributor

@alamb alamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good to me, thank you @jayzhan211

Now that I am looking at this code, I wonder why array literals can't support functions 🤔 I bet they could given they are just arguments passed to a function now

@jayzhan211
Copy link
Contributor Author

looks good to me, thank you @jayzhan211

Now that I am looking at this code, I wonder why array literals can't support functions 🤔 I bet they could given they are just arguments passed to a function now

True

@jayzhan211 jayzhan211 marked this pull request as draft January 17, 2024 23:22
Signed-off-by: jayzhan211 <[email protected]>
@jayzhan211 jayzhan211 changed the title Support array literal with struct Support array literal with scalar function Jan 17, 2024
}
}
}
let values = elements
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I love it -- less code and more functionality ❤️ !

@jayzhan211 jayzhan211 marked this pull request as ready for review January 18, 2024 03:09
@jayzhan211
Copy link
Contributor Author

Forgot to convert back from draft, this is ready to merge!

@jackwener jackwener merged commit 57e38fb into apache:main Jan 18, 2024
23 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sql SQL Planner sqllogictest SQL Logic Tests (.slt)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Support array literal with struct Calling make_array() on struct literal causes panic
3 participants